-- GENERATED SPELL FOR [Maraudine Khan Guard] --


function spell0_6069(pUnit, Event) --@Defensive Stance,Self--
pUnit:FullCastSpellOnTarget(7164,pUnit)
pUnit:RegisterEvent('Sorts_6069', 622, 1)
end

function spell1_6069(pUnit, Event) --@Shield Bash,n/a--
pUnit:FullCastSpellOnTarget(11972,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_6069', 8319, 1)
end

function spell2_6069(pUnit, Event) --@Sunder Armor,n/a--
pUnit:FullCastSpellOnTarget(11971,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_6069', 30263, 1)
end

function Sorts_6069(pUnit, Event)
local choix_sorts_6069 = math.random(0, 2)
if choix_sorts_6069 == 0 then
pUnit:RegisterEvent('spell0_6069', 1, 1)
end
if choix_sorts_6069 == 1 then
pUnit:RegisterEvent('spell1_6069', 1, 1)
end
if choix_sorts_6069 == 2 then
pUnit:RegisterEvent('spell2_6069', 1, 1)
end
end

function mob6069_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_6069', math.random(1500, 3000), 1)
end

function mob6069_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob6069_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob6069_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(6069, 1, 'mob6069_Action')
RegisterUnitEvent(6069, 2, 'mob6069_Leave')
RegisterUnitEvent(6069, 3, 'mob6069_Kill')
RegisterUnitEvent(6069, 4, 'mob6069_Die')
